package freedom.sample.tcp;

import java.io.IOException;
import java.net.InetAddress;
import java.net.InetSocketAddress;
import java.net.Socket;
import java.net.SocketAddress;

public class ClientApp 
{
    public void init() throws IOException
    {
    	Socket sever = null;
    	try {
    		sever = new Socket();
    		InetAddress addr = null;
    		int port = 0;
    		SocketAddress socketAddress = new InetSocketAddress(addr, port);
    		int timeout = 0;//与服务端建立连接的时限
    		sever.connect(socketAddress, timeout);
    		int soTimeout = 0;//读时限
    		sever.setSoTimeout(soTimeout);
//    		sever.getChannel().configureBlocking(block)
		} finally {
			// TODO: handle finally clause
			if(sever != null)
				sever.close();
		}
    }
}
